const webpack = require('webpack');
const baseConfig = require('./webpack.base.js')
const VueSSRClientPlugin = require("vue-server-renderer/client-plugin")
const merge = require('webpack-merge')

module.exports = merge(baseConfig,{
	entry:{
		main:'./app/config/client.js'
	},
	plugins:[
		//重要信息 ：这将webpack运行时分离到一个引导块中，以便可以在之后正确注入异步 模块
		//这也为应用程序 vendor代码提供了更更好的缓存
		new webpack.optimize.CommonsChunkPlugin({
      name: "manifest",
      minChunks: Infinity
    }),
		//如果不添加name 将默认输出vue-ssr-client-manifest.json
		new VueSSRClientPlugin()
	]
})
